<?php

use think\migration\Migrator;
use think\migration\db\Column;

class AlterAdminAddRoleId extends Migrator
{
    public function up()
    {
        $this->table('admin')
            ->addColumn('role_id', 'integer', ['limit' => 11, 'default' => 0, 'comment' => '角色'])
            ->update();
    }

    public function down()
    {
        $this->table('admin')->removeColumn('role_id');
    }
}
